package com.cskaoyan.mapper;

import com.cskaoyan.bean.Ad;
import com.cskaoyan.bean.AdExample;
import com.cskaoyan.bean.vo.AdminAdForListItemBean;
import com.cskaoyan.weixin.bean.home.BannerBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface AdMapper {
    long countByExample(AdExample example);

    int deleteByExample(AdExample example);

  //  int deleteByPrimaryKey(Integer id);

    int insert(Ad record);

    int insertSelective(Ad record);

    List<Ad> selectByExample(AdExample example);

    List<AdminAdForListItemBean> selectAdminAdForListItemBean(AdExample example);

 //   Ad selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") Ad record, @Param("example") AdExample example);

    int updateByExample(@Param("record") Ad record, @Param("example") AdExample example);

    int updateByPrimaryKeySelective(Ad record);

    int updateByPrimaryKey(Ad record);

    Integer insertAdByAdminAdForListItemBean(@Param("adBean") AdminAdForListItemBean adBean);


    Integer updateByAdminAdForListItemBean(@Param("adBean") AdminAdForListItemBean adBean);

    AdminAdForListItemBean selectAdminAdForListItemBeanById(@Param("id") Integer id);

    List<BannerBean> selectBanner();

}